package com.csf.service;

import com.csf.entity.LoginTicket;
import com.csf.entity.User;
import org.springframework.security.core.GrantedAuthority;

import java.util.Collection;
import java.util.Map;

public interface UserService {
    User findUserById(int id);

    Map<String,Object> register(User user);

    int activationCode(int userId,String code);

    Map<String,Object> login(String username,String password,int Time_Long);

    void updateTicket(String ticket);

    LoginTicket findLoginTicket(String ticket);

    User findUserByUsername(String toName);

    Collection<? extends GrantedAuthority> getAuthorities(int userId);
}
